JCSProB: Implementing Integrated Formal Specifications in Concurrent Java
نویسندگان
چکیده
The ProB model checker provides tool support for an integrated formal specification approach, which combines the classical state-based B language with the event-based process algebra CSP. In this paper, we present a developing strategy for implementing such a combined ProB specification as a concurrent Java program. A Java implementation of the combined B and CSP model has been developed using a similar approach to JCSP. A set of translation rules relates the formal model to its Java implementation, and we also provide a translation tool JCSProB to automatically generate a Java program from a ProB specification. To demonstrate and exercise the tool, several B/CSP models, varying both in syntactic structure and behavioural/concurrency properties, are translated by the tool. The models manifest the presence and absence of various safety, deadlock, and bounded fairness properties; the generated Java code is shown to faithfully reproduce them. Run-time safety and bounded fairness checking is also demonstrated. The Java programs are discussed to demonstrate our implementation of the abstract B/CSP concurrency model in Java. In conclusion we consider the effectiveness and generality of the implementation strategy.
منابع مشابه
Java implementation platform for the integrated state- and event-based specification in PROB
PROB is an animation and model checking tool, which supports integrated eventand state-based specifications combining B and CSP. We present an initial strategy for implementing the combined specification model as a concurrent Java program. Our Java implementation for the combined B and CSP model uses a similar approach to that of JCSP. The restricted operational semantics for the integrated B a...
متن کاملAutomatic Translation from Combined B and CSP Specification to Java Programs
A recent contribution to the formal specification and verification of concurrent systems is the integration of the stateand event-based approaches B and CSP, specifically in the ProB model checking tool. At the implementation end of the development, concurrent programming in Java remains a demanding and error-prone activity, because of the need to verify critical properties of safety and livene...
متن کاملFrom Formal Specifications to Ready-to-Use Software Components: The Concurrent Object Oriented Petri Net Approach
CO-OPN (Concurrent Object Oriented Petri Net) is a formal specification language for modelling distributed systems; it is based on coordinated algebraic Petri nets. In this paper we describe a method for generating an executable prototype from a CO-OPN specification. We focus our discussion on the generation of executable code for COOPN classes. CO-OPN classes are defined using Petri Nets. The ...
متن کاملFormal Verification of Java Code Generation from UML Models
UML specifications offer the advantage to describe software systems while the actual task of implementing code for them is passed to code generators that automatically produce e.g. Java code. For safety reasons, it is necessary that the generated code is semantically equivalent to the original UML specification. In this paper, we present our approach to formally verify within the Isabelle/HOL t...
متن کاملA History of BlockingQueues
This paper describes a way to formally specify the behaviour of concurrent data structures. When specifying concurrent data structures, the main challenge is to make specifications stable, i.e., to ensure that they cannot be invalidated by other threads. To this end, we propose to use history-based specifications: instead of describing method behaviour in terms of the object’s state, we specify...
متن کامل